package com.health.patient.server.controller;

import com.health.common.core.web.domain.AjaxResult;
import com.health.health.common.dto.PmsMessTextingDto;
import com.health.patient.server.service.MessageService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class MessageController {

    @Autowired
    private MessageService messageService;


    /**
     * 医生发送群发消息
     * @param messTextingDto
     * @return
     * ybz
     */
    @PostMapping("/sendMessage")
    public AjaxResult sendMessage(@RequestBody PmsMessTextingDto messTextingDto) throws Exception {
        return messageService.sendMessage(messTextingDto);
    }
}
